<%@ page contentType="text/html; charset=UTF-8" language="java" %>
<%@page import="org.quickbundle.orgauth.util.impl.RmOrgService"%>
<%@page import="java.util.ArrayList"%>
<%@page import="java.util.HashMap"%>
<%@page import="java.util.Map"%>
<%@page import="org.quickbundle.project.common.vo.RmCommonVo"%>
<%@page import="org.quickbundle.project.RmProjectHelper"%>
<%@ page import="java.util.List" %>
<%@page import="org.quickbundle.tools.helper.RmVoHelper"%>
<%@page import="org.quickbundle.tools.helper.RmJspHelper"%>
<%@page import="org.quickbundle.project.RmGlobalReference"%>
<%@page import="org.quickbundle.base.web.page.RmPageVo"%>
<%@ page import="org.quickbundle.orgauth.rmuser.vo.RmUserVo" %>
<%@ page import="org.quickbundle.orgauth.rmuser.util.IRmUserConstants" %>
<%@page import="org.quickbundle.base.beans.factory.RmBeanFactory"%>
<%@page import="org.quickbundle.orgauth.IOrgauthConstants"%>
<%@page import="com.dfhc.util.CryptoHelper"%>
<%@ page contentType="text/html; charset=UTF-8" language="java"%>
<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<%@ taglib uri="/dfhc" prefix="dfhc" %>
<!-- 全局js 和css包 -->
<%@ include file="/jsp/include/web/new/global.jsp" %>
<title>用户管理</title>
<script type="text/javascript" src="<%=request.getContextPath()%>/js/rm-tools.js"></script>
</head>


<body>

<article class="page-container">

	<form action="" method="post" class="form form-horizontal" id="form-add" >
	  <dfhc:tr>
		<dfhc:td>
          <b><font class=p12>系统管理 	&gt;&gt; 用户管理	&gt;&gt; 分配角色 	&gt;&gt; 当前员工名称：</font><font color=red class=p14>${rmUserVo.name}</font></b>&nbsp;&nbsp;
        </dfhc:td>
	  </dfhc:tr>
	    	<br>
	    	<dfhc:tr>
				<dfhc:td><b>全局角色：</b></dfhc:td>
			</dfhc:tr>   
	    	<dfhc:table templateId="table_h_ui" > 
				<c:forEach items="${isSystemLevelList}" var="list"    > 
				<dfhc:tr  > 
				<dfhc:td >
					<dfhc:checkbox  name="role_name"  value="${list.id}"  />
				</dfhc:td>
				<dfhc:td>
				  ${list.name} (${list.role_code})
				</dfhc:td>
				</dfhc:tr  >
				</c:forEach> 
			</dfhc:table>
		  <br>
		  <dfhc:tr>
				<td><b>公司角色</b></td>
			</dfhc:tr> 
			<dfhc:table templateId="table_h_ui" > 
			 
				<c:forEach items="${notSystemLevelList}" var="list" begin='0' step='1' varStatus="status"  > 
				<dfhc:tr   > 
				<dfhc:td >
					<dfhc:checkbox name="role_name"  value="${list.id}"  />
				</dfhc:td>
				<dfhc:td>
				   ${list.name} (${list.role_code})
				</dfhc:td>
				</dfhc:tr  >
				</c:forEach> 
			</dfhc:table>
			<dfhc:div templateId="h_ui_div_row_cl">
			<dfhc:div templateId="h_ui_div_pop_up_button">
				<dfhc:button templateId="h_ui_author_button" onclick="_singleAuth('/newRmUser/insertPartyRole','${party_id}')" />
			</dfhc:div>
		    </dfhc:div> 
	</form>
	
</article>


 
</body>
<script type="text/javascript">
//授权
function _singleAuth(url,id){
	debugger;
	url = getRootPath()+url;
	var ssurl= getRootPath()+'<%=CryptoHelper.encryptUrl(request,"/newRmUser")%>';
	var ids = '${rmUserVo.id}';
	var newUrl=url+'?id='+ids;
	submitAjax(newUrl,$("#form-add").serialize(),ssurl);
	layer.closeAll();
}

<% 
HashMap sWriteBack=(HashMap<String,Object>)request.getAttribute("sWriteBack");
out.print(RmVoHelper.writeBackMapToForm(sWriteBack));
%>
</script>
</html>